Skip to content

Changed sha1 into bcrypt #3356

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed

Changed sha1 into bcrypt #3356

wants to merge 1 commit into from

Conversation

wouterj
Copy link
Member

@wouterj wouterj commented Dec 17, 2013

Q A
Doc fix? yes
New docs? no
Applies to 2.2+ (bcrypt was introduced in 2.2)
Fixed tickets https://twitter.com/ircmaxell/status/412978651123023872

We loose some information, but I don't think that information is necessary. I also made the change without testing it, so: Needs some review!

/cc @ircmaxell @weaverryan

@@ -1358,6 +1358,15 @@ the password is simply run through the ``sha1`` algorithm one time and without
any extra encoding. You can now calculate the hashed password either programmatically
(e.g. ``hash('sha1', 'ryanpass')``) or via some online tool like `functions-online.com`_

.. caution::

The above example is not meaned for practical usage, it uses a weak hash
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left the above example with sha1, because when using bcrypt it would be hard to get the hashed password.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is not meant

@Incognito
Copy link
Contributor

A larger change to the docs may be more suitable for the reader.

For example we could move this section to be entirely on use of bcrypt and add an extra page elsewhere that describe pbkdf2 usage, and we can group "legacy hashing" algos like MD5, Rot13, Sha1, etc.

@1ed
Copy link
Contributor

1ed commented Dec 22, 2013

You should add a note about the requirements somewhere. To use the BCrypt encoder, you need to upgrade to PHP 5.5 or install the "ircmaxell/password-compat" via Composer ... see BCryptPasswordEncoder

weaverryan added a commit that referenced this pull request Jan 2, 2014
… details in intro area that aren't necessary (you'll need to read the cookbook entry for more details anyways)
weaverryan added a commit that referenced this pull request Jan 2, 2014
Also removing one example (now possible with using bcrypt from the beginning) and related tweaks.
weaverryan added a commit that referenced this pull request Jan 2, 2014
Also filling in other details related to using BCrypt
@weaverryan
Copy link
Member

Thanks for starting with Wouter! I've continued the conversation with a new PR at #3405 with some additional changes.

Thanks!

@weaverryan weaverryan closed this Jan 2, 2014
@wouterj wouterj deleted the security_fix branch January 2, 2014 01:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants